package com.xingchen.loveparttimejob.uitls;

import com.sun.source.tree.NewArrayTree;
import com.xingchen.loveparttimejob.model.vo.ResponseData;

import java.nio.charset.CoderMalfunctionError;

/**
 * 返回给前端的数据工具
 * @author 小志
 * @date 2024/12/9 - 15:15
 */
public class ResponseDataUtils {
    private static final ResponseData RESPONSE_DATA = new ResponseData();
    public static ResponseData generateResponseData(Integer code,String type,String message,Object Data){
        RESPONSE_DATA.setCode(code);
        RESPONSE_DATA.setType(type);
        RESPONSE_DATA.setMessage(message);
        RESPONSE_DATA.setData(Data);
        return RESPONSE_DATA;
    }
}
